﻿using System.Configuration;

namespace Tilver.Configuration.Logging
{
    public class AppenderElement : ConfigurationElement
    {
        /// <summary>
        /// 节点名称
        /// </summary>
        [ConfigurationProperty("name", IsRequired = true, IsKey = true)]
        public string Name
        {
            get { return (string)this["name"]; }
            set { this["name"] = value; }
        }
        /// <summary>
        /// 是否覆盖
        /// </summary>
        [ConfigurationProperty("isReplacer", DefaultValue = true)]
        public bool IsReplacer
        {
            get { return (bool)this["isReplacer"]; }
            set { this["isReplacer"] = value; }
        }
        /// <summary>
        /// 是否抛出异常
        /// </summary>
        [ConfigurationProperty("throwException", DefaultValue = false)]
        public bool ThrowException
        {
            get { return (bool)this["throwException"]; }
            set { this["throwException"] = value; }
        }
    }
}
